package com.zidongxiangxi.rabbit.starter.entity;

import com.zidongxiangxi.rabbit.starter.entity.consumer.ReliableRabbitConsumer;
import com.zidongxiangxi.rabbit.starter.entity.producer.ReliableRabbitProducer;
import org.springframework.boot.context.properties.ConfigurationProperties;

/**
 * 可靠RabbitMQ配置类
 *
 * @author chenxudong
 * @date 2020/11/08
 */
@ConfigurationProperties(prefix = "reliable-rabbit")
public class ReliableRabbitProperties {
	/**
	 * 应用名
	 */
	private String application;

	/**
	 * zookeeper地址
	 */
	private String zookeeperAddress;

	/**
	 * 发送配置
	 */
	private final ReliableRabbitProducer producer = new ReliableRabbitProducer();

	/**
	 * 消费配置
	 */
	private final ReliableRabbitConsumer consumer = new ReliableRabbitConsumer();

	public String getApplication() {
		return application;
	}

	public void setApplication(String application) {
		this.application = application;
	}

	public String getZookeeperAddress() {
		return zookeeperAddress;
	}

	public void setZookeeperAddress(String zookeeperAddress) {
		this.zookeeperAddress = zookeeperAddress;
	}

	public ReliableRabbitProducer getProducer() {
		return producer;
	}

	public ReliableRabbitConsumer getConsumer() {
		return consumer;
	}
}
